<div class="fm-content">
    <!-- 最上面标题栏 -->
    <div class="title">
        <i nz-icon [type]="'desktop'"></i>
        &nbsp;&nbsp;旅客安全检查
    </div>
    <!-- 内容 -->
    <div class="work">

        <!-- 查询框 -->
        <div class="top">
            <!-- first-input -->
            <nz-select class="fm-input first-input" (nzOpenChange)="airportDic.load('0')"
                [(ngModel)]="fs.queryObject['airport:=']" [nzPlaceHolder]="'所属机场'">
                <nz-option *ngFor="let option of airportDic.datas" [nzLabel]="option.display" [nzValue]="option.id">
                </nz-option>
                <nz-option *ngIf="airportDic.isLoading" nzDisabled nzCustomContent>
                    <i nz-icon type="loading" class="loading-icon"></i>加载中...
                </nz-option>
            </nz-select>
            <nz-button-group>
                <button nz-button nzType="primary" (click)="fs.loadData(true)">查询</button>
                <button nz-button (click)="fs.resetQueryObject() && fs.loadData(true)">重置</button>
            </nz-button-group>
            <div class="tool-right">
                <nz-button-group>
                    <button *ngIf="ss.mi.sa || ss.mi.lkaqjcxz" nz-button [nzType]="'primary'" (click)="editRow(null)">新增</button>
                    <!-- <button nz-button (click)="fs.editRow()">编辑</button> -->
                    <button *ngIf="ss.mi.sa || ss.mi.lkaqjcsc" nz-popconfirm nzTitle="确认删除选择项?" (nzOnConfirm)="fs.delEntitys()" nzPlacement="bottomRight"
                        nz-button>删除</button>
                  <a nz-button href="assets/images/旅客安全检查.xls" download="旅客安全检查.xls">模板下载</a>
                  <button nz-button (click)="fs.export('xjmh_lkaq.html', '旅客安全检查.xls')">导出</button>
                  <nz-upload nzAction="{{ fs.getExcelUploadUrl() }}" [nzLimit]="1" [nzHeaders]="ffs.fileHeaders"
                             [nzFilter]="fs.excelFilters" [nzAccept]="'.xls,.xlsx'" (nzChange)="excelHandleChange($event)">
                    <button *ngIf="ss.mi.sa || ss.mi.lkaqjcxz" nz-button>导入</button>
                  </nz-upload>
                </nz-button-group>
            </div>
        </div>

        <!-- 右则样表单主体 -->
        <div class="work-content">
            <div class="table">
                <nz-table nzSize="middle" nzBordered nzShowSizeChanger [nzPageSizeOptions]='[ 10, 15, 20, 30, 40, 50 ]'
                    [nzFrontPagination]="false" [nzData]="fs.datas" [nzLoading]="fs.isLoading || fs.isDeleing"
                    [nzTotal]="fs.rowsCount" [(nzPageIndex)]="fs.pageIndex" [(nzPageSize)]="fs.pageSize"
                    (nzPageIndexChange)="fs.loadData()" (nzPageSizeChange)="fs.loadData(true)"
                    [nzWidthConfig]="['50px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px','100px']"
                    [nzScroll]="{x: '3400px' }">
                    <thead>
                        <tr>
                            <th rowspan="3" nzShowCheckbox [(nzChecked)]="fs.allChecked"
                                [nzIndeterminate]="fs.indeterminate" (nzCheckedChange)="fs.checkAll($event)"></th>
                            <th rowspan="3" [nzAlign]="'center'">所属机场</th>
                            <th colspan="5">旅客人身检查</th>
                            <th colspan="14">旅客人身及随身物品检查</th>
                            <th colspan="13">旅客托运行李检查</th>
                        </tr>
                        <tr>
                            <th>共计</th>
                            <th colspan="4">其中查获</th>
                            <th>共计</th>
                            <th colspan="13">其中查获</th>
                            <th>共计</th>
                            <th colspan="12">其中查获</th>
                        </tr>
                        <tr>
                            <th>检查人数</th>
                            <th>伪造、变造身份证</th>
                            <th>冒用身份证</th>
                            <th>小计</th>
                            <th>违法犯罪人员</th>
                            <th>检查件数</th>
                            <th>枪支(含仿真枪)</th>
                            <th>弹药</th>
                            <th>军械、警械</th>
                            <th>爆破器材</th>
                            <th>电击器等防卫器具</th>
                            <th>管制刀具</th>
                            <th>6公分以上非管制刀具</th>
                            <th>易燃易爆物品</th>
                            <th>火种类</th>
                            <th>超规锂电池</th>
                            <th>毒品</th>
                            <th>其他违禁品和危险品</th>
                            <th>小计</th>
                            <th>检查件数</th>
                            <th>枪支(含仿真枪)</th>
                            <th>弹药</th>
                            <th>军械、警械</th>
                            <th>爆破器材</th>
                            <th>电击器等防卫器具</th>
                            <th>管制刀具</th>
                            <th>易燃易爆物品</th>
                            <th>火种类</th>
                            <th>超规锂电池</th>
                            <th>毒品</th>
                            <th>其他违禁品和危险品</th>
                            <th>小计</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr *ngFor="let data of fs.datas">
                            <td nzShowCheckbox [(nzChecked)]="data.checked" (nzCheckedChange)="fs.refreshCheckStatus()">
                            </td>
                            <!-- <td><span (click)="fs.editRow(data)" class="form-edit"></span></td> -->
                            <td [nzAlign]="'center'"><span (click)="editRow(data)"
                                    class="form-edit">{{data.airportName}}</span></td>
                            <td>{{data.pcheckcount}}</td>
                            <td>{{data.pfakeidcard}}</td>
                            <td>{{data.ppersonateidcard}}</td>
                            <td>{{data.ptotal}}</td>
                            <td>{{data.pcriminal}}</td>
                            <td>{{data.gcheckcount}}</td>
                            <td>{{data.gguns}}</td>
                            <td>{{data.gbullet}}</td>
                            <td>{{data.gpoliceequipment}}</td>
                            <td>{{data.gboomequipment}}</td>
                            <td>{{data.gelecequipment}}</td>
                            <td>{{data.gcontrolknife}}</td>
                            <td>{{data.glongknife}}</td>
                            <td>{{data.gdanger}}</td>
                            <td>{{data.gfire}}</td>
                            <td>{{data.glibattery}}</td>
                            <td>{{data.gdrugs}}</td>
                            <td>{{data.gother}}</td>
                            <td>{{data.gtotal}}</td>
                            <td>{{data.bcheckcount}}</td>
                            <td>{{data.bguns}}</td>
                            <td>{{data.bbullet}}</td>
                            <td>{{data.bpoliceequipment}}</td>
                            <td>{{data.bboomequipment}}</td>
                            <td>{{data.belecequipment}}</td>
                            <td>{{data.bcontrolknife}}</td>
                            <td>{{data.bdanger}}</td>
                            <td>{{data.bfire}}</td>
                            <td>{{data.blibattery}}</td>
                            <td>{{data.bdrugs}}</td>
                            <td>{{data.bother}}</td>
                            <td>{{data.btotal}}</td>
                        </tr>
                    </tbody>
                </nz-table>
            </div>
        </div>
    </div>
</div>
